Dimensionality Reduction for Gesture Recognition Time Series Data

1. Introduction

Gestures have recently become attractive for spontaneous interaction with consumer electronics and mobile devices in the context of pervasive computing. One related article about this topic starts with the following statement: “Gestures have recently become attractive for spontaneous interaction with consumer electronics and mobile devices in the context of pervasive computing”.

In that work, Liu et al.(2009) present uWave to address some challenges to gesture-based interaction and focus on gestures without regard to finger movement, such as sign languages. Unlike statistical methods, uWave only requires a single training sample to start and only employs a three-axis accelerometer that has already appeared in numerous consumer electronics, e.g. Nintendo Wii remote, and mobile device, e.g. Apple iPhone.

At the end, Liu et al. evaluate uWave with a gesture vocabulary for which they have collected a library of 4480 gestures from eight participants over multiple weeks. The aim is to provide efficient personalized gesture recognition on wide range of devices. The library, uWaveGestureLibrary, consists over 4000 instances each of which has the accelerometer readings in three dimensions (i.e. x, y and z). Eight gestures are illustrated below.

Gesture classes

The main purpose in this assignment is to consuct the Principal Component Analysis(PCA)in order to induce the information of 3 dimensions into 1 dimension. Also, the dimensionality of time from 315 is reduced ro 2 which means, we may use much more few columns to describe the gesture of the users than the whole data. Before starting the tasks, the data is downloaded from the url and the necessary adjustments are conducted.

2. Data Preprocess

There are separate files for each axis and each row corresponds to one gesture in the files. First column has the class information. The information between second and last column is the time ordered observations in the corresponding axis (provided in the file name as X, Y or Z). In order to arrange the data for the following tasks, five functions are created which ease the calculation in the data preprocessing part. The explanation of these functions can be seen below.

1. preparation function: Imports the data and renames the columns.
2. transformation function: Transforms the wide data format into long data format which is also known as melting the data.
3. position function: Calculates the coordinates from accelerometer information.
4. pca_plot function: Plots the first component of the Principal Component Analysis for randomly selected two instances of the class.
5. pca_class function: Applies Principal Component Analysis to each class separately.

Later, the uWave Gesture data have been imported from the provided source, and the functions are used.

The following tables are given to visualize how the data set is organized after using these functions. Tables show times from 1 to 10 with the first 50 rows.

X Coordinate Train Table
Class X Train 1 X Train 2 X Train 3 X Train 4 X Train 5 X Train 6 X Train 7 X Train 8 X Train 9 X Train 10
6 -0.3042432 -0.3042432 -0.3042432 -0.3042432 -0.3042432 -0.3042432 -0.3042432 -0.3042432 -0.3042432 -0.3042432
5 1.6273111 1.6273111 1.6273111 1.6273111 1.6273111 1.6273111 1.6273111 1.6273111 1.6273111 1.6273111
5 0.6612765 0.6612765 0.6612765 0.6612765 0.6612765 0.6612765 0.6612765 0.6612765 0.6612765 0.6612765
3 0.0051848 0.0051848 0.0051848 0.0051848 0.0051848 0.0051848 0.0051848 0.0051848 0.0051848 0.0051848
4 1.2861978 1.2861978 1.2861978 1.2861978 1.2861978 1.2861978 1.2861978 1.2861978 1.2861978 1.2861978
8 -0.4792525 -0.4792525 -0.4792525 -0.4792525 -0.4792525 -0.4792525 -0.4792525 -0.4792525 -0.4792525 -0.4792525
7 1.4743277 1.4743277 1.4743277 1.4743277 1.4743277 1.4743277 1.4743277 1.4743277 1.4743277 1.4743277
4 0.3053030 0.3053030 0.3053030 0.3053030 0.3053030 0.3053030 0.3053030 0.3053030 0.3053030 0.3053030
4 0.9808104 0.9808104 0.9808104 0.9808104 0.9808104 0.9808104 0.9808104 0.9808104 0.9808104 0.9808104
6 -1.1770783 -1.1770783 -1.1770783 -1.1770783 -1.1770783 -1.1770783 -1.1770783 -1.1770783 -1.1770783 -1.1770783
1 -0.7914472 -0.7914472 -0.7958727 -0.8100650 -0.8492300 -0.9034648 -0.9311463 -0.9506034 -0.9506034 -0.9506034
7 0.0370984 0.0370984 0.0370984 0.0370984 0.0370984 0.0370984 0.0370984 0.0370984 0.0370984 0.0370984
3 -0.5957553 -0.5957553 -0.5957553 -0.5957553 -0.5957553 -0.5957553 -0.5957553 -0.5957553 -0.5957553 -0.5957553
5 -0.1727133 -0.1727133 -0.1727133 -0.1727133 -0.1727133 -0.1727133 -0.1727133 -0.1727133 -0.1727133 -0.1727133
2 1.1995068 1.1995068 1.2332168 1.3256785 1.3632054 1.3787227 1.3787227 1.3787227 1.3787227 1.3787227
6 0.8205179 0.8205179 0.8205179 0.8205179 0.8205179 0.8205179 0.8205179 0.8205179 0.8205179 0.8205179
1 -0.4496024 -0.4496024 -0.4496024 -0.4496024 -0.4496024 -0.4496024 -0.4496024 -0.4496024 -0.4496024 -0.4496024
6 -0.1356258 -0.1356258 -0.1356258 -0.1356258 -0.1356258 -0.1356258 -0.1356258 -0.1356258 -0.1356258 -0.1356258
1 -0.1874689 -0.1874689 -0.1874689 -0.1874689 -0.1874689 -0.1874689 -0.1874689 -0.1874689 -0.1874689 -0.1874689
2 0.1385765 0.1385765 0.1385765 0.1385765 0.1385765 0.1385765 0.1385765 0.1385765 0.1385765 0.1385765
8 -0.5005661 -0.5005661 -0.5005661 -0.5005661 -0.5005661 -0.5005661 -0.5005661 -0.5005661 -0.5005661 -0.5005661
6 1.5880751 1.5880751 1.5880751 1.5880751 1.5880751 1.5880751 1.5880751 1.5880751 1.5880751 1.5880751
1 0.3014817 0.3014817 0.3014817 0.3014817 0.3014817 0.3014817 0.3014817 0.3014817 0.3014817 0.3014817
7 0.5110611 0.5110611 0.5110611 0.5110611 0.5110611 0.5110611 0.5110611 0.5110611 0.5110611 0.5110611
8 -0.6343623 -0.6343623 -0.6343623 -0.6343623 -0.6343623 -0.6343623 -0.6343623 -0.6343623 -0.6343623 -0.6343623
7 -0.7432730 -0.7432730 -0.7432730 -0.7432730 -0.7432730 -0.7432730 -0.7432730 -0.7432730 -0.7432730 -0.7432730
3 -0.6903765 -0.6903765 -0.6903765 -0.6903765 -0.6903765 -0.6903765 -0.6903765 -0.6903765 -0.6903765 -0.6903765
6 1.1972450 1.1972450 1.1972450 1.1972450 1.1972450 1.1972450 1.1972450 1.1972450 1.1972450 1.1972450
2 0.4128329 0.4128329 0.4128329 0.4128329 0.4128329 0.4128329 0.4128329 0.4128329 0.4128329 0.4128329
6 -1.0354143 -1.0354143 -1.0354143 -1.0354143 -1.0354143 -1.0354143 -1.0354143 -1.0354143 -1.0354143 -1.0354143
2 0.0239700 0.0239700 0.0239700 0.0239700 0.0239700 0.0239700 0.0239700 0.0239700 0.0239700 0.0531401
7 1.0741608 1.0741608 1.0741608 1.0741608 1.0741608 1.0741608 1.0741608 1.0741608 1.0741608 1.0741608
8 1.0491965 1.0621332 1.0750698 1.0854786 1.0958874 1.0958874 1.0958874 1.0958874 1.0958874 1.0958874
4 0.5423736 0.5423736 0.5423736 0.5423736 0.5423736 0.5423736 0.5423736 0.5423736 0.5423736 0.5423736
5 -0.1050939 -0.1050939 -0.1050939 -0.1050939 -0.1050939 -0.1050939 -0.1050939 -0.1050939 -0.1050939 -0.1050939
6 -0.1762893 -0.1762893 -0.1762893 -0.1762893 -0.1762893 -0.1762893 -0.1762893 -0.1762893 -0.1762893 -0.1762893
8 -0.2023839 -0.2023839 -0.2023839 -0.2023839 -0.2023839 -0.2023839 -0.2023839 -0.2023839 -0.2023839 -0.2023839
1 0.1632022 0.1632022 0.1632022 0.1632022 0.1632022 0.1632022 0.1632022 0.1632022 0.1632022 0.1632022
7 1.4444565 1.4444565 1.4444565 1.4444565 1.4444565 1.4444565 1.4444565 1.4444565 1.4444565 1.4444565
8 -0.2174123 -0.2174123 -0.2174123 -0.2174123 -0.2174123 -0.2174123 -0.2496209 -0.2900378 -0.3486763 -0.3784380
5 -0.0802111 -0.0802111 -0.0802111 -0.0802111 -0.0802111 -0.0802111 -0.0802111 -0.0802111 -0.0802111 -0.0802111
6 -1.0663609 -1.0663609 -1.0663609 -1.0663609 -1.0663609 -1.0663609 -1.0663609 -1.0663609 -1.0663609 -1.0663609
1 -0.9319900 -0.9319900 -0.9319900 -0.9319900 -0.9319900 -0.9319900 -0.9319900 -0.9319900 -0.9319900 -0.9319900
6 0.9459161 0.9459161 0.9459161 0.9459161 0.9459161 0.9459161 0.9459161 0.9459161 0.9459161 0.9459161
5 1.4915011 1.4915011 1.4915011 1.4915011 1.4915011 1.4915011 1.4915011 1.4915011 1.4915011 1.4915011
1 -0.0809128 -0.0809128 -0.0809128 -0.0809128 -0.0809128 -0.0809128 -0.0809128 -0.0809128 -0.0809128 -0.0809128
7 0.8267532 0.8267532 0.8267532 0.8267532 0.8267532 0.8267532 0.8267532 0.8267532 0.8267532 0.8267532
8 -0.6037743 -0.6037743 -0.6037743 -0.6037743 -0.6037743 -0.6037743 -0.6037743 -0.6037743 -0.6037743 -0.6013603
1 -0.6406994 -0.6406994 -0.6406994 -0.6406994 -0.6406994 -0.6406994 -0.6406994 -0.6406994 -0.6406994 -0.6406994
5 1.3854165 1.3854165 1.3854165 1.3854165 1.3854165 1.3854165 1.3854165 1.3854165 1.3854165 1.3854165
Y Coordinate Train Table
Class Y Train 1 Y Train 2 Y Train 3 Y Train 4 Y Train 5 Y Train 6 Y Train 7 Y Train 8 Y Train 9 Y Train 10
6 -2.1193958 -2.1193958 -2.1193958 -2.1193958 -2.1193958 -2.1193958 -2.1193958 -2.1193958 -2.1193958 -2.1193958
5 0.6666238 0.6666238 0.6666238 0.6666238 0.6666238 0.6666238 0.6666238 0.6666238 0.6666238 0.6666238
5 -0.1897302 -0.1897302 -0.1897302 -0.1897302 -0.1897302 -0.1897302 -0.1897302 -0.1897302 -0.1897302 -0.1897302
3 0.3740667 0.3740667 0.3740667 0.3740667 0.3740667 0.3740667 0.3740667 0.3740667 0.3740667 0.3740667
4 -0.3974369 -0.3974369 -0.3974369 -0.3974369 -0.3974369 -0.3974369 -0.3974369 -0.3974369 -0.3974369 -0.3974369
8 -1.0800804 -1.0800804 -1.0800804 -1.0800804 -1.0800804 -1.0800804 -1.0800804 -1.0800804 -1.0800804 -1.0800804
7 1.2592868 1.2592868 1.2592868 1.2592868 1.2592868 1.2592868 1.2592868 1.2592868 1.2592868 1.2592868
4 -0.3299549 -0.3299549 -0.3299549 -0.3299549 -0.3299549 -0.3299549 -0.3299549 -0.3299549 -0.3299549 -0.3299549
4 0.3823780 0.3823780 0.3823780 0.3823780 0.3823780 0.3823780 0.3823780 0.3823780 0.3823780 0.3823780
6 -1.2054435 -1.2054435 -1.2054435 -1.2054435 -1.2054435 -1.2054435 -1.2054435 -1.2054435 -1.2054435 -1.2054435
1 -1.9599838 -1.9599838 -1.9566005 -1.9457505 -1.9158091 -1.8743468 -1.8531844 -1.8383095 -1.8383095 -1.8383095
7 0.4316975 0.4316975 0.4316975 0.4316975 0.4316975 0.4316975 0.4316975 0.4316975 0.4316975 0.4316975
3 -0.9437350 -0.9437350 -0.9437350 -0.9437350 -0.9437350 -0.9437350 -0.9437350 -0.9437350 -0.9437350 -0.9437350
5 -0.3743780 -0.3743780 -0.3743780 -0.3743780 -0.3743780 -0.3743780 -0.3743780 -0.3743780 -0.3743780 -0.3743780
2 1.6272883 1.6272883 1.6272883 1.6272883 1.6272883 1.6272883 1.6272883 1.6272883 1.6272883 1.6272883
6 -1.3893431 -1.3893431 -1.3893431 -1.3893431 -1.3893431 -1.3893431 -1.3893431 -1.3893431 -1.3893431 -1.3893431
1 -1.9712004 -1.9712004 -1.9712004 -1.9712004 -1.9712004 -1.9712004 -1.9712004 -1.9712004 -1.9712004 -1.9712004
6 -0.7238205 -0.7238205 -0.7238205 -0.7238205 -0.7238205 -0.7238205 -0.7238205 -0.7238205 -0.7238205 -0.7238205
1 -1.2364488 -1.2364488 -1.2364488 -1.2364488 -1.2364488 -1.2364488 -1.2364488 -1.2364488 -1.2364488 -1.2364488
2 -0.5564547 -0.5564547 -0.5564547 -0.5564547 -0.5564547 -0.5564547 -0.5564547 -0.5564547 -0.5564547 -0.5564547
8 -0.9163918 -0.9163918 -0.9163918 -0.9163918 -0.9163918 -0.9163918 -0.9163918 -0.9163918 -0.9163918 -0.9163918
6 -1.5482695 -1.5482695 -1.5482695 -1.5482695 -1.5482695 -1.5482695 -1.5482695 -1.5482695 -1.5482695 -1.5482695
1 -1.4935131 -1.4935131 -1.4935131 -1.4935131 -1.4935131 -1.4935131 -1.4935131 -1.4935131 -1.4935131 -1.4935131
7 0.0362150 0.0362150 0.0362150 0.0362150 0.0362150 0.0362150 0.0362150 0.0362150 0.0362150 0.0362150
8 -0.2621215 -0.2621215 -0.2621215 -0.2621215 -0.2621215 -0.2621215 -0.2621215 -0.2621215 -0.2621215 -0.2621215
7 -0.8737314 -0.8737314 -0.8737314 -0.8737314 -0.8737314 -0.8737314 -0.8737314 -0.8737314 -0.8737314 -0.8737314
3 -1.6390544 -1.6390544 -1.6390544 -1.6390544 -1.6390544 -1.6390544 -1.6390544 -1.6390544 -1.6390544 -1.6390544
6 -1.3064385 -1.3064385 -1.3064385 -1.3064385 -1.3064385 -1.3064385 -1.3064385 -1.3064385 -1.3064385 -1.3064385
2 0.3794462 0.3794462 0.3794462 0.3794462 0.3794462 0.3794462 0.3794462 0.3794462 0.3794462 0.3794462
6 0.6013732 0.6013732 0.6013732 0.6013732 0.6013732 0.6013732 0.6013732 0.6013732 0.6013732 0.6013732
2 0.6937350 0.6937350 0.6937350 0.6937350 0.6937350 0.6937350 0.6937350 0.6937350 0.6937350 0.6937350
7 -0.4823754 -0.4823754 -0.4823754 -0.4823754 -0.4823754 -0.4823754 -0.4823754 -0.4823754 -0.4823754 -0.4823754
8 0.1627292 0.2951243 0.4275193 0.5340441 0.6405688 0.6405688 0.6405688 0.6405688 0.6405688 0.6405688
4 -0.5667598 -0.5667598 -0.5667598 -0.5667598 -0.5667598 -0.5667598 -0.5667598 -0.5667598 -0.5667598 -0.5667598
5 0.5252014 0.5252014 0.5252014 0.5252014 0.5252014 0.5252014 0.5252014 0.5252014 0.5252014 0.5252014
6 -1.1215457 -1.1215457 -1.1215457 -1.1215457 -1.1215457 -1.1215457 -1.1215457 -1.1215457 -1.1215457 -1.1215457
8 0.3331062 0.3331062 0.3331062 0.3331062 0.3331062 0.3331062 0.3331062 0.3331062 0.3331062 0.3331062
1 -0.6158814 -0.6158814 -0.6158814 -0.6158814 -0.6158814 -0.6158814 -0.6158814 -0.6158814 -0.6158814 -0.6158814
7 1.5087920 1.5087920 1.5087920 1.5087920 1.5087920 1.5087920 1.5087920 1.5087920 1.5087920 1.5087920
8 -1.3791072 -1.3791072 -1.3791072 -1.3791072 -1.3791072 -1.3791072 -1.3791072 -1.3791072 -1.3791072 -1.3791072
5 0.5551865 0.5551865 0.5551865 0.5551865 0.5551865 0.5551865 0.5551865 0.5551865 0.5551865 0.5551865
6 -1.1525699 -1.1525699 -1.1525699 -1.1525699 -1.1525699 -1.1525699 -1.1525699 -1.1525699 -1.1525699 -1.1525699
1 -1.6753297 -1.6753297 -1.6753297 -1.6753297 -1.6753297 -1.6753297 -1.6753297 -1.6753297 -1.6753297 -1.6753297
6 -1.5242835 -1.5242835 -1.5242835 -1.5242835 -1.5242835 -1.5242835 -1.5242835 -1.5242835 -1.5242835 -1.5242835
5 1.0498150 1.0498150 1.0498150 1.0498150 1.0498150 1.0498150 1.0498150 1.0498150 1.0498150 1.0498150
1 -1.2327774 -1.2327774 -1.2327774 -1.2327774 -1.2327774 -1.2327774 -1.2327774 -1.2327774 -1.2327774 -1.2327774
7 0.6419082 0.6419082 0.6574072 0.6921938 0.7544357 0.7979510 0.7979510 0.7979510 0.7979510 0.7979510
8 -0.4068866 -0.4068866 -0.4068866 -0.4068866 -0.4068866 -0.4068866 -0.4068866 -0.4068866 -0.4068866 -0.4040015
1 -1.9267647 -1.9267647 -1.9267647 -1.9267647 -1.9267647 -1.9267647 -1.9267647 -1.9267647 -1.9267647 -1.9267647
5 1.2290439 1.2290439 1.2290439 1.2290439 1.2290439 1.2290439 1.2290439 1.2290439 1.2290439 1.2290439
Z Coordinate Train Table
Class Z Train 1 Z Train 2 Z Train 3 Z Train 4 Z Train 5 Z Train 6 Z Train 7 Z Train 8 Z Train 9 Z Train 10
6 -1.5289651 -1.5289651 -1.5289651 -1.5289651 -1.5289651 -1.5289651 -1.5289651 -1.5289651 -1.5289651 -1.5289651
5 1.7868688 1.7868688 1.7868688 1.7868688 1.7868688 1.7868688 1.7868688 1.7868688 1.7868688 1.7868688
5 0.5212487 0.5212487 0.5212487 0.5212487 0.5212487 0.5212487 0.5212487 0.5212487 0.5212487 0.5212487
3 0.3094552 0.3094552 0.3094552 0.3094552 0.3094552 0.3094552 0.3094552 0.3094552 0.3094552 0.3094552
4 -0.4660215 -0.4660215 -0.4660215 -0.4660215 -0.4660215 -0.4660215 -0.4660215 -0.4660215 -0.4660215 -0.4660215
8 0.6564008 0.6564008 0.6564008 0.6564008 0.6564008 0.6564008 0.6564008 0.6564008 0.6564008 0.6564008
7 1.2374173 1.2374173 1.2374173 1.2374173 1.2374173 1.2374173 1.2374173 1.2374173 1.2374173 1.2374173
4 -1.2987178 -1.2987178 -1.2987178 -1.2987178 -1.2987178 -1.2987178 -1.2987178 -1.2987178 -1.2987178 -1.2987178
4 -0.6951287 -0.6951287 -0.6951287 -0.6951287 -0.6951287 -0.6951287 -0.6951287 -0.6951287 -0.6951287 -0.6951287
6 -1.3194905 -1.3194905 -1.3194905 -1.3194905 -1.3194905 -1.3194905 -1.3194905 -1.3194905 -1.3194905 -1.3194905
1 -0.2490781 -0.2490781 -0.2514390 -0.2590101 -0.2799033 -0.3088358 -0.3236030 -0.3339827 -0.3339827 -0.3339827
7 0.6699316 0.6699316 0.6699316 0.6699316 0.6699316 0.6699316 0.6699316 0.6699316 0.6699316 0.6699316
3 1.2540429 1.2540429 1.2540429 1.2540429 1.2540429 1.2540429 1.2540429 1.2540429 1.2540429 1.2540429
5 -0.0737382 -0.0737382 -0.0737382 -0.0737382 -0.0737382 -0.0737382 -0.0737382 -0.0737382 -0.0737382 -0.0737382
2 1.9515678 1.9515678 1.9397498 1.9073345 1.8941783 1.8887383 1.8887383 1.8887383 1.8887383 1.8887383
6 -1.0537573 -1.0537573 -1.0537573 -1.0537573 -1.0537573 -1.0537573 -1.0537573 -1.0537573 -1.0537573 -1.0537573
1 -1.2897498 -1.2897498 -1.2897498 -1.2897498 -1.2897498 -1.2897498 -1.2897498 -1.2897498 -1.2897498 -1.2897498
6 -0.3964898 -0.3964898 -0.3964898 -0.3964898 -0.3964898 -0.3964898 -0.3964898 -0.3964898 -0.3964898 -0.3964898
1 -0.8108461 -0.8108461 -0.8108461 -0.8108461 -0.8108461 -0.8108461 -0.8108461 -0.8108461 -0.8108461 -0.8108461
2 1.9231438 1.9231438 1.9231438 1.9231438 1.9231438 1.9231438 1.9231438 1.9231438 1.9231438 1.9231438
8 -0.1986017 -0.1986017 -0.1986017 -0.1986017 -0.1986017 -0.1986017 -0.1986017 -0.1986017 -0.1986017 -0.1986017
6 -1.5865603 -1.5865603 -1.5865603 -1.5865603 -1.5865603 -1.5865603 -1.5865603 -1.5865603 -1.5865603 -1.5865603
1 -1.1472344 -1.1472344 -1.1472344 -1.1472344 -1.1472344 -1.1472344 -1.1472344 -1.1472344 -1.1472344 -1.1472344
7 0.6798272 0.6798272 0.6798272 0.6798272 0.6798272 0.6798272 0.6798272 0.6798272 0.6798272 0.6798272
8 -0.0414692 -0.0414692 -0.0414692 -0.0414692 -0.0414692 -0.0414692 -0.0414692 -0.0414692 -0.0414692 -0.0414692
7 0.1348167 0.1348167 0.1348167 0.1348167 0.1348167 0.1348167 0.1348167 0.1348167 0.1348167 0.1348167
3 -0.9403235 -0.9403235 -0.9403235 -0.9403235 -0.9403235 -0.9403235 -0.9403235 -0.9403235 -0.9403235 -0.9403235
6 -1.0725211 -1.0725211 -1.0725211 -1.0725211 -1.0725211 -1.0725211 -1.0725211 -1.0725211 -1.0725211 -1.0725211
2 1.3374179 1.3374179 1.3374179 1.3374179 1.3374179 1.3374179 1.3374179 1.3374179 1.3374179 1.3374179
6 -0.2899900 -0.2899900 -0.2899900 -0.2899900 -0.2899900 -0.2899900 -0.2899900 -0.2899900 -0.2899900 -0.2899900
2 -0.3800553 -0.3800553 -0.3800553 -0.3800553 -0.3800553 -0.3800553 -0.3800553 -0.3800553 -0.3800553 -0.3599844
7 -0.0639523 -0.0639523 -0.0639523 -0.0639523 -0.0639523 -0.0639523 -0.0639523 -0.0639523 -0.0639523 -0.0639523
8 1.6031458 1.5440837 1.4850216 1.4375004 1.3899792 1.3899792 1.3899792 1.3899792 1.3899792 1.3899792
4 0.0712592 0.0712592 0.0712592 0.0712592 0.0712592 0.0712592 0.0712592 0.0712592 0.0712592 0.0712592
5 0.1582337 0.1582337 0.1582337 0.1582337 0.1582337 0.1582337 0.1582337 0.1582337 0.1582337 0.1582337
6 -0.5022619 -0.5022619 -0.5022619 -0.5022619 -0.5022619 -0.5022619 -0.5022619 -0.5022619 -0.5022619 -0.5022619
8 1.1354097 1.1354097 1.1354097 1.1354097 1.1354097 1.1354097 1.1354097 1.1354097 1.1354097 1.1354097
1 -1.3271478 -1.3271478 -1.3271478 -1.3271478 -1.3271478 -1.3271478 -1.3271478 -1.3271478 -1.3271478 -1.3271478
7 1.1263460 1.1263460 1.1263460 1.1263460 1.1263460 1.1263460 1.1263460 1.1263460 1.1263460 1.1263460
8 -0.5584607 -0.5584607 -0.5584607 -0.5584607 -0.5584607 -0.5584607 -0.5427308 -0.5229920 -0.4943543 -0.4798193
5 -0.1891761 -0.1891761 -0.1891761 -0.1891761 -0.1891761 -0.1891761 -0.1891761 -0.1891761 -0.1891761 -0.1891761
6 -1.2592308 -1.2592308 -1.2592308 -1.2592308 -1.2592308 -1.2592308 -1.2592308 -1.2592308 -1.2592308 -1.2592308
1 -1.8033172 -1.8033172 -1.8033172 -1.8033172 -1.8033172 -1.8033172 -1.8033172 -1.8033172 -1.8033172 -1.8033172
6 -1.6240061 -1.6240061 -1.6240061 -1.6240061 -1.6240061 -1.6240061 -1.6240061 -1.6240061 -1.6240061 -1.6240061
5 1.8907394 1.8907394 1.8907394 1.8907394 1.8907394 1.8907394 1.8907394 1.8907394 1.8907394 1.8907394
1 -1.2951504 -1.2951504 -1.2951504 -1.2951504 -1.2951504 -1.2951504 -1.2951504 -1.2951504 -1.2951504 -1.2951504
7 0.3000316 0.3000316 0.3059416 0.3192064 0.3429404 0.3595336 0.3595336 0.3595336 0.3595336 0.3595336
8 -0.1905289 -0.1905289 -0.1905289 -0.1905289 -0.1905289 -0.1905289 -0.1905289 -0.1905289 -0.1905289 -0.1884399
1 -1.4575673 -1.4575673 -1.4575673 -1.4575673 -1.4575673 -1.4575673 -1.4575673 -1.4575673 -1.4575673 -1.4575673
5 1.3204229 1.3204229 1.3204229 1.3204229 1.3204229 1.3204229 1.3204229 1.3204229 1.3204229 1.3204229
Wide Data Table with X, Y, and Z Coordinates
Class X Train 1 X Train 2 X Train 3 X Train 4 X Train 5 X Train 6 X Train 7 X Train 8 X Train 9 X Train 10 Y Train 1 Y Train 2 Y Train 3 Y Train 4 Y Train 5 Y Train 6 Y Train 7 Y Train 8 Y Train 9 Y Train 10 Z Train 1 Z Train 2 Z Train 3 Z Train 4 Z Train 5 Z Train 6 Z Train 7 Z Train 8 Z Train 9 Z Train 10
6 -0.3042432 -0.3042432 -0.3042432 -0.3042432 -0.3042432 -0.3042432 -0.3042432 -0.3042432 -0.3042432 -0.3042432 -2.1193958 -2.1193958 -2.1193958 -2.1193958 -2.1193958 -2.1193958 -2.1193958 -2.1193958 -2.1193958 -2.1193958 -1.5289651 -1.5289651 -1.5289651 -1.5289651 -1.5289651 -1.5289651 -1.5289651 -1.5289651 -1.5289651 -1.5289651
5 1.6273111 1.6273111 1.6273111 1.6273111 1.6273111 1.6273111 1.6273111 1.6273111 1.6273111 1.6273111 0.6666238 0.6666238 0.6666238 0.6666238 0.6666238 0.6666238 0.6666238 0.6666238 0.6666238 0.6666238 1.7868688 1.7868688 1.7868688 1.7868688 1.7868688 1.7868688 1.7868688 1.7868688 1.7868688 1.7868688
5 0.6612765 0.6612765 0.6612765 0.6612765 0.6612765 0.6612765 0.6612765 0.6612765 0.6612765 0.6612765 -0.1897302 -0.1897302 -0.1897302 -0.1897302 -0.1897302 -0.1897302 -0.1897302 -0.1897302 -0.1897302 -0.1897302 0.5212487 0.5212487 0.5212487 0.5212487 0.5212487 0.5212487 0.5212487 0.5212487 0.5212487 0.5212487
3 0.0051848 0.0051848 0.0051848 0.0051848 0.0051848 0.0051848 0.0051848 0.0051848 0.0051848 0.0051848 0.3740667 0.3740667 0.3740667 0.3740667 0.3740667 0.3740667 0.3740667 0.3740667 0.3740667 0.3740667 0.3094552 0.3094552 0.3094552 0.3094552 0.3094552 0.3094552 0.3094552 0.3094552 0.3094552 0.3094552
4 1.2861978 1.2861978 1.2861978 1.2861978 1.2861978 1.2861978 1.2861978 1.2861978 1.2861978 1.2861978 -0.3974369 -0.3974369 -0.3974369 -0.3974369 -0.3974369 -0.3974369 -0.3974369 -0.3974369 -0.3974369 -0.3974369 -0.4660215 -0.4660215 -0.4660215 -0.4660215 -0.4660215 -0.4660215 -0.4660215 -0.4660215 -0.4660215 -0.4660215
8 -0.4792525 -0.4792525 -0.4792525 -0.4792525 -0.4792525 -0.4792525 -0.4792525 -0.4792525 -0.4792525 -0.4792525 -1.0800804 -1.0800804 -1.0800804 -1.0800804 -1.0800804 -1.0800804 -1.0800804 -1.0800804 -1.0800804 -1.0800804 0.6564008 0.6564008 0.6564008 0.6564008 0.6564008 0.6564008 0.6564008 0.6564008 0.6564008 0.6564008
7 1.4743277 1.4743277 1.4743277 1.4743277 1.4743277 1.4743277 1.4743277 1.4743277 1.4743277 1.4743277 1.2592868 1.2592868 1.2592868 1.2592868 1.2592868 1.2592868 1.2592868 1.2592868 1.2592868 1.2592868 1.2374173 1.2374173 1.2374173 1.2374173 1.2374173 1.2374173 1.2374173 1.2374173 1.2374173 1.2374173
4 0.3053030 0.3053030 0.3053030 0.3053030 0.3053030 0.3053030 0.3053030 0.3053030 0.3053030 0.3053030 -0.3299549 -0.3299549 -0.3299549 -0.3299549 -0.3299549 -0.3299549 -0.3299549 -0.3299549 -0.3299549 -0.3299549 -1.2987178 -1.2987178 -1.2987178 -1.2987178 -1.2987178 -1.2987178 -1.2987178 -1.2987178 -1.2987178 -1.2987178
4 0.9808104 0.9808104 0.9808104 0.9808104 0.9808104 0.9808104 0.9808104 0.9808104 0.9808104 0.9808104 0.3823780 0.3823780 0.3823780 0.3823780 0.3823780 0.3823780 0.3823780 0.3823780 0.3823780 0.3823780 -0.6951287 -0.6951287 -0.6951287 -0.6951287 -0.6951287 -0.6951287 -0.6951287 -0.6951287 -0.6951287 -0.6951287
6 -1.1770783 -1.1770783 -1.1770783 -1.1770783 -1.1770783 -1.1770783 -1.1770783 -1.1770783 -1.1770783 -1.1770783 -1.2054435 -1.2054435 -1.2054435 -1.2054435 -1.2054435 -1.2054435 -1.2054435 -1.2054435 -1.2054435 -1.2054435 -1.3194905 -1.3194905 -1.3194905 -1.3194905 -1.3194905 -1.3194905 -1.3194905 -1.3194905 -1.3194905 -1.3194905
1 -0.7914472 -0.7914472 -0.7958727 -0.8100650 -0.8492300 -0.9034648 -0.9311463 -0.9506034 -0.9506034 -0.9506034 -1.9599838 -1.9599838 -1.9566005 -1.9457505 -1.9158091 -1.8743468 -1.8531844 -1.8383095 -1.8383095 -1.8383095 -0.2490781 -0.2490781 -0.2514390 -0.2590101 -0.2799033 -0.3088358 -0.3236030 -0.3339827 -0.3339827 -0.3339827
7 0.0370984 0.0370984 0.0370984 0.0370984 0.0370984 0.0370984 0.0370984 0.0370984 0.0370984 0.0370984 0.4316975 0.4316975 0.4316975 0.4316975 0.4316975 0.4316975 0.4316975 0.4316975 0.4316975 0.4316975 0.6699316 0.6699316 0.6699316 0.6699316 0.6699316 0.6699316 0.6699316 0.6699316 0.6699316 0.6699316
3 -0.5957553 -0.5957553 -0.5957553 -0.5957553 -0.5957553 -0.5957553 -0.5957553 -0.5957553 -0.5957553 -0.5957553 -0.9437350 -0.9437350 -0.9437350 -0.9437350 -0.9437350 -0.9437350 -0.9437350 -0.9437350 -0.9437350 -0.9437350 1.2540429 1.2540429 1.2540429 1.2540429 1.2540429 1.2540429 1.2540429 1.2540429 1.2540429 1.2540429
5 -0.1727133 -0.1727133 -0.1727133 -0.1727133 -0.1727133 -0.1727133 -0.1727133 -0.1727133 -0.1727133 -0.1727133 -0.3743780 -0.3743780 -0.3743780 -0.3743780 -0.3743780 -0.3743780 -0.3743780 -0.3743780 -0.3743780 -0.3743780 -0.0737382 -0.0737382 -0.0737382 -0.0737382 -0.0737382 -0.0737382 -0.0737382 -0.0737382 -0.0737382 -0.0737382
2 1.1995068 1.1995068 1.2332168 1.3256785 1.3632054 1.3787227 1.3787227 1.3787227 1.3787227 1.3787227 1.6272883 1.6272883 1.6272883 1.6272883 1.6272883 1.6272883 1.6272883 1.6272883 1.6272883 1.6272883 1.9515678 1.9515678 1.9397498 1.9073345 1.8941783 1.8887383 1.8887383 1.8887383 1.8887383 1.8887383
6 0.8205179 0.8205179 0.8205179 0.8205179 0.8205179 0.8205179 0.8205179 0.8205179 0.8205179 0.8205179 -1.3893431 -1.3893431 -1.3893431 -1.3893431 -1.3893431 -1.3893431 -1.3893431 -1.3893431 -1.3893431 -1.3893431 -1.0537573 -1.0537573 -1.0537573 -1.0537573 -1.0537573 -1.0537573 -1.0537573 -1.0537573 -1.0537573 -1.0537573
1 -0.4496024 -0.4496024 -0.4496024 -0.4496024 -0.4496024 -0.4496024 -0.4496024 -0.4496024 -0.4496024 -0.4496024 -1.9712004 -1.9712004 -1.9712004 -1.9712004 -1.9712004 -1.9712004 -1.9712004 -1.9712004 -1.9712004 -1.9712004 -1.2897498 -1.2897498 -1.2897498 -1.2897498 -1.2897498 -1.2897498 -1.2897498 -1.2897498 -1.2897498 -1.2897498
6 -0.1356258 -0.1356258 -0.1356258 -0.1356258 -0.1356258 -0.1356258 -0.1356258 -0.1356258 -0.1356258 -0.1356258 -0.7238205 -0.7238205 -0.7238205 -0.7238205 -0.7238205 -0.7238205 -0.7238205 -0.7238205 -0.7238205 -0.7238205 -0.3964898 -0.3964898 -0.3964898 -0.3964898 -0.3964898 -0.3964898 -0.3964898 -0.3964898 -0.3964898 -0.3964898
1 -0.1874689 -0.1874689 -0.1874689 -0.1874689 -0.1874689 -0.1874689 -0.1874689 -0.1874689 -0.1874689 -0.1874689 -1.2364488 -1.2364488 -1.2364488 -1.2364488 -1.2364488 -1.2364488 -1.2364488 -1.2364488 -1.2364488 -1.2364488 -0.8108461 -0.8108461 -0.8108461 -0.8108461 -0.8108461 -0.8108461 -0.8108461 -0.8108461 -0.8108461 -0.8108461
2 0.1385765 0.1385765 0.1385765 0.1385765 0.1385765 0.1385765 0.1385765 0.1385765 0.1385765 0.1385765 -0.5564547 -0.5564547 -0.5564547 -0.5564547 -0.5564547 -0.5564547 -0.5564547 -0.5564547 -0.5564547 -0.5564547 1.9231438 1.9231438 1.9231438 1.9231438 1.9231438 1.9231438 1.9231438 1.9231438 1.9231438 1.9231438
8 -0.5005661 -0.5005661 -0.5005661 -0.5005661 -0.5005661 -0.5005661 -0.5005661 -0.5005661 -0.5005661 -0.5005661 -0.9163918 -0.9163918 -0.9163918 -0.9163918 -0.9163918 -0.9163918 -0.9163918 -0.9163918 -0.9163918 -0.9163918 -0.1986017 -0.1986017 -0.1986017 -0.1986017 -0.1986017 -0.1986017 -0.1986017 -0.1986017 -0.1986017 -0.1986017
6 1.5880751 1.5880751 1.5880751 1.5880751 1.5880751 1.5880751 1.5880751 1.5880751 1.5880751 1.5880751 -1.5482695 -1.5482695 -1.5482695 -1.5482695 -1.5482695 -1.5482695 -1.5482695 -1.5482695 -1.5482695 -1.5482695 -1.5865603 -1.5865603 -1.5865603 -1.5865603 -1.5865603 -1.5865603 -1.5865603 -1.5865603 -1.5865603 -1.5865603
1 0.3014817 0.3014817 0.3014817 0.3014817 0.3014817 0.3014817 0.3014817 0.3014817 0.3014817 0.3014817 -1.4935131 -1.4935131 -1.4935131 -1.4935131 -1.4935131 -1.4935131 -1.4935131 -1.4935131 -1.4935131 -1.4935131 -1.1472344 -1.1472344 -1.1472344 -1.1472344 -1.1472344 -1.1472344 -1.1472344 -1.1472344 -1.1472344 -1.1472344
7 0.5110611 0.5110611 0.5110611 0.5110611 0.5110611 0.5110611 0.5110611 0.5110611 0.5110611 0.5110611 0.0362150 0.0362150 0.0362150 0.0362150 0.0362150 0.0362150 0.0362150 0.0362150 0.0362150 0.0362150 0.6798272 0.6798272 0.6798272 0.6798272 0.6798272 0.6798272 0.6798272 0.6798272 0.6798272 0.6798272
8 -0.6343623 -0.6343623 -0.6343623 -0.6343623 -0.6343623 -0.6343623 -0.6343623 -0.6343623 -0.6343623 -0.6343623 -0.2621215 -0.2621215 -0.2621215 -0.2621215 -0.2621215 -0.2621215 -0.2621215 -0.2621215 -0.2621215 -0.2621215 -0.0414692 -0.0414692 -0.0414692 -0.0414692 -0.0414692 -0.0414692 -0.0414692 -0.0414692 -0.0414692 -0.0414692
7 -0.7432730 -0.7432730 -0.7432730 -0.7432730 -0.7432730 -0.7432730 -0.7432730 -0.7432730 -0.7432730 -0.7432730 -0.8737314 -0.8737314 -0.8737314 -0.8737314 -0.8737314 -0.8737314 -0.8737314 -0.8737314 -0.8737314 -0.8737314 0.1348167 0.1348167 0.1348167 0.1348167 0.1348167 0.1348167 0.1348167 0.1348167 0.1348167 0.1348167
3 -0.6903765 -0.6903765 -0.6903765 -0.6903765 -0.6903765 -0.6903765 -0.6903765 -0.6903765 -0.6903765 -0.6903765 -1.6390544 -1.6390544 -1.6390544 -1.6390544 -1.6390544 -1.6390544 -1.6390544 -1.6390544 -1.6390544 -1.6390544 -0.9403235 -0.9403235 -0.9403235 -0.9403235 -0.9403235 -0.9403235 -0.9403235 -0.9403235 -0.9403235 -0.9403235
6 1.1972450 1.1972450 1.1972450 1.1972450 1.1972450 1.1972450 1.1972450 1.1972450 1.1972450 1.1972450 -1.3064385 -1.3064385 -1.3064385 -1.3064385 -1.3064385 -1.3064385 -1.3064385 -1.3064385 -1.3064385 -1.3064385 -1.0725211 -1.0725211 -1.0725211 -1.0725211 -1.0725211 -1.0725211 -1.0725211 -1.0725211 -1.0725211 -1.0725211
2 0.4128329 0.4128329 0.4128329 0.4128329 0.4128329 0.4128329 0.4128329 0.4128329 0.4128329 0.4128329 0.3794462 0.3794462 0.3794462 0.3794462 0.3794462 0.3794462 0.3794462 0.3794462 0.3794462 0.3794462 1.3374179 1.3374179 1.3374179 1.3374179 1.3374179 1.3374179 1.3374179 1.3374179 1.3374179 1.3374179
6 -1.0354143 -1.0354143 -1.0354143 -1.0354143 -1.0354143 -1.0354143 -1.0354143 -1.0354143 -1.0354143 -1.0354143 0.6013732 0.6013732 0.6013732 0.6013732 0.6013732 0.6013732 0.6013732 0.6013732 0.6013732 0.6013732 -0.2899900 -0.2899900 -0.2899900 -0.2899900 -0.2899900 -0.2899900 -0.2899900 -0.2899900 -0.2899900 -0.2899900
2 0.0239700 0.0239700 0.0239700 0.0239700 0.0239700 0.0239700 0.0239700 0.0239700 0.0239700 0.0531401 0.6937350 0.6937350 0.6937350 0.6937350 0.6937350 0.6937350 0.6937350 0.6937350 0.6937350 0.6937350 -0.3800553 -0.3800553 -0.3800553 -0.3800553 -0.3800553 -0.3800553 -0.3800553 -0.3800553 -0.3800553 -0.3599844
7 1.0741608 1.0741608 1.0741608 1.0741608 1.0741608 1.0741608 1.0741608 1.0741608 1.0741608 1.0741608 -0.4823754 -0.4823754 -0.4823754 -0.4823754 -0.4823754 -0.4823754 -0.4823754 -0.4823754 -0.4823754 -0.4823754 -0.0639523 -0.0639523 -0.0639523 -0.0639523 -0.0639523 -0.0639523 -0.0639523 -0.0639523 -0.0639523 -0.0639523
8 1.0491965 1.0621332 1.0750698 1.0854786 1.0958874 1.0958874 1.0958874 1.0958874 1.0958874 1.0958874 0.1627292 0.2951243 0.4275193 0.5340441 0.6405688 0.6405688 0.6405688 0.6405688 0.6405688 0.6405688 1.6031458 1.5440837 1.4850216 1.4375004 1.3899792 1.3899792 1.3899792 1.3899792 1.3899792 1.3899792
4 0.5423736 0.5423736 0.5423736 0.5423736 0.5423736 0.5423736 0.5423736 0.5423736 0.5423736 0.5423736 -0.5667598 -0.5667598 -0.5667598 -0.5667598 -0.5667598 -0.5667598 -0.5667598 -0.5667598 -0.5667598 -0.5667598 0.0712592 0.0712592 0.0712592 0.0712592 0.0712592 0.0712592 0.0712592 0.0712592 0.0712592 0.0712592
5 -0.1050939 -0.1050939 -0.1050939 -0.1050939 -0.1050939 -0.1050939 -0.1050939 -0.1050939 -0.1050939 -0.1050939 0.5252014 0.5252014 0.5252014 0.5252014 0.5252014 0.5252014 0.5252014 0.5252014 0.5252014 0.5252014 0.1582337 0.1582337 0.1582337 0.1582337 0.1582337 0.1582337 0.1582337 0.1582337 0.1582337 0.1582337
6 -0.1762893 -0.1762893 -0.1762893 -0.1762893 -0.1762893 -0.1762893 -0.1762893 -0.1762893 -0.1762893 -0.1762893 -1.1215457 -1.1215457 -1.1215457 -1.1215457 -1.1215457 -1.1215457 -1.1215457 -1.1215457 -1.1215457 -1.1215457 -0.5022619 -0.5022619 -0.5022619 -0.5022619 -0.5022619 -0.5022619 -0.5022619 -0.5022619 -0.5022619 -0.5022619
8 -0.2023839 -0.2023839 -0.2023839 -0.2023839 -0.2023839 -0.2023839 -0.2023839 -0.2023839 -0.2023839 -0.2023839 0.3331062 0.3331062 0.3331062 0.3331062 0.3331062 0.3331062 0.3331062 0.3331062 0.3331062 0.3331062 1.1354097 1.1354097 1.1354097 1.1354097 1.1354097 1.1354097 1.1354097 1.1354097 1.1354097 1.1354097
1 0.1632022 0.1632022 0.1632022 0.1632022 0.1632022 0.1632022 0.1632022 0.1632022 0.1632022 0.1632022 -0.6158814 -0.6158814 -0.6158814 -0.6158814 -0.6158814 -0.6158814 -0.6158814 -0.6158814 -0.6158814 -0.6158814 -1.3271478 -1.3271478 -1.3271478 -1.3271478 -1.3271478 -1.3271478 -1.3271478 -1.3271478 -1.3271478 -1.3271478
7 1.4444565 1.4444565 1.4444565 1.4444565 1.4444565 1.4444565 1.4444565 1.4444565 1.4444565 1.4444565 1.5087920 1.5087920 1.5087920 1.5087920 1.5087920 1.5087920 1.5087920 1.5087920 1.5087920 1.5087920 1.1263460 1.1263460 1.1263460 1.1263460 1.1263460 1.1263460 1.1263460 1.1263460 1.1263460 1.1263460
8 -0.2174123 -0.2174123 -0.2174123 -0.2174123 -0.2174123 -0.2174123 -0.2496209 -0.2900378 -0.3486763 -0.3784380 -1.3791072 -1.3791072 -1.3791072 -1.3791072 -1.3791072 -1.3791072 -1.3791072 -1.3791072 -1.3791072 -1.3791072 -0.5584607 -0.5584607 -0.5584607 -0.5584607 -0.5584607 -0.5584607 -0.5427308 -0.5229920 -0.4943543 -0.4798193
5 -0.0802111 -0.0802111 -0.0802111 -0.0802111 -0.0802111 -0.0802111 -0.0802111 -0.0802111 -0.0802111 -0.0802111 0.5551865 0.5551865 0.5551865 0.5551865 0.5551865 0.5551865 0.5551865 0.5551865 0.5551865 0.5551865 -0.1891761 -0.1891761 -0.1891761 -0.1891761 -0.1891761 -0.1891761 -0.1891761 -0.1891761 -0.1891761 -0.1891761
6 -1.0663609 -1.0663609 -1.0663609 -1.0663609 -1.0663609 -1.0663609 -1.0663609 -1.0663609 -1.0663609 -1.0663609 -1.1525699 -1.1525699 -1.1525699 -1.1525699 -1.1525699 -1.1525699 -1.1525699 -1.1525699 -1.1525699 -1.1525699 -1.2592308 -1.2592308 -1.2592308 -1.2592308 -1.2592308 -1.2592308 -1.2592308 -1.2592308 -1.2592308 -1.2592308
1 -0.9319900 -0.9319900 -0.9319900 -0.9319900 -0.9319900 -0.9319900 -0.9319900 -0.9319900 -0.9319900 -0.9319900 -1.6753297 -1.6753297 -1.6753297 -1.6753297 -1.6753297 -1.6753297 -1.6753297 -1.6753297 -1.6753297 -1.6753297 -1.8033172 -1.8033172 -1.8033172 -1.8033172 -1.8033172 -1.8033172 -1.8033172 -1.8033172 -1.8033172 -1.8033172
6 0.9459161 0.9459161 0.9459161 0.9459161 0.9459161 0.9459161 0.9459161 0.9459161 0.9459161 0.9459161 -1.5242835 -1.5242835 -1.5242835 -1.5242835 -1.5242835 -1.5242835 -1.5242835 -1.5242835 -1.5242835 -1.5242835 -1.6240061 -1.6240061 -1.6240061 -1.6240061 -1.6240061 -1.6240061 -1.6240061 -1.6240061 -1.6240061 -1.6240061
5 1.4915011 1.4915011 1.4915011 1.4915011 1.4915011 1.4915011 1.4915011 1.4915011 1.4915011 1.4915011 1.0498150 1.0498150 1.0498150 1.0498150 1.0498150 1.0498150 1.0498150 1.0498150 1.0498150 1.0498150 1.8907394 1.8907394 1.8907394 1.8907394 1.8907394 1.8907394 1.8907394 1.8907394 1.8907394 1.8907394
1 -0.0809128 -0.0809128 -0.0809128 -0.0809128 -0.0809128 -0.0809128 -0.0809128 -0.0809128 -0.0809128 -0.0809128 -1.2327774 -1.2327774 -1.2327774 -1.2327774 -1.2327774 -1.2327774 -1.2327774 -1.2327774 -1.2327774 -1.2327774 -1.2951504 -1.2951504 -1.2951504 -1.2951504 -1.2951504 -1.2951504 -1.2951504 -1.2951504 -1.2951504 -1.2951504
7 0.8267532 0.8267532 0.8267532 0.8267532 0.8267532 0.8267532 0.8267532 0.8267532 0.8267532 0.8267532 0.6419082 0.6419082 0.6574072 0.6921938 0.7544357 0.7979510 0.7979510 0.7979510 0.7979510 0.7979510 0.3000316 0.3000316 0.3059416 0.3192064 0.3429404 0.3595336 0.3595336 0.3595336 0.3595336 0.3595336
8 -0.6037743 -0.6037743 -0.6037743 -0.6037743 -0.6037743 -0.6037743 -0.6037743 -0.6037743 -0.6037743 -0.6013603 -0.4068866 -0.4068866 -0.4068866 -0.4068866 -0.4068866 -0.4068866 -0.4068866 -0.4068866 -0.4068866 -0.4040015 -0.1905289 -0.1905289 -0.1905289 -0.1905289 -0.1905289 -0.1905289 -0.1905289 -0.1905289 -0.1905289 -0.1884399
1 -0.6406994 -0.6406994 -0.6406994 -0.6406994 -0.6406994 -0.6406994 -0.6406994 -0.6406994 -0.6406994 -0.6406994 -1.9267647 -1.9267647 -1.9267647 -1.9267647 -1.9267647 -1.9267647 -1.9267647 -1.9267647 -1.9267647 -1.9267647 -1.4575673 -1.4575673 -1.4575673 -1.4575673 -1.4575673 -1.4575673 -1.4575673 -1.4575673 -1.4575673 -1.4575673
5 1.3854165 1.3854165 1.3854165 1.3854165 1.3854165 1.3854165 1.3854165 1.3854165 1.3854165 1.3854165 1.2290439 1.2290439 1.2290439 1.2290439 1.2290439 1.2290439 1.2290439 1.2290439 1.2290439 1.2290439 1.3204229 1.3204229 1.3204229 1.3204229 1.3204229 1.3204229 1.3204229 1.3204229 1.3204229 1.3204229
X Coordinate Train Table Long Format
Class Time Series Time Index X
6 1 1 -0.3042432
6 1 2 -0.3042432
6 1 3 -0.3042432
6 1 4 -0.3042432
6 1 5 -0.3042432
6 1 6 -0.3042432
6 1 7 -0.3042432
6 1 8 -0.3042432
6 1 9 -0.3042432
6 1 10 -0.3042432
6 1 11 -0.3042432
6 1 12 -0.3042432
6 1 13 -0.3042432
6 1 14 -0.3042432
6 1 15 -0.3042432
6 1 16 -0.3042432
6 1 17 -0.3042432
6 1 18 -0.3042432
6 1 19 -0.3042432
6 1 20 -0.2408078
6 1 21 -0.1773724
6 1 22 -0.0680011
6 1 23 0.0413702
6 1 24 0.1507415
6 1 25 0.2601129
6 1 26 0.3213608
6 1 27 0.3826088
6 1 28 0.3826088
6 1 29 0.3826088
6 1 30 0.3826088
6 1 31 0.3826088
6 1 32 0.3826088
6 1 33 0.3826088
6 1 34 0.3826088
6 1 35 0.3826088
6 1 36 0.3826088
6 1 37 0.3826088
6 1 38 0.3826088
6 1 39 0.3826088
6 1 40 0.3826088
6 1 41 0.3826088
6 1 42 0.3826088
6 1 43 0.3826088
6 1 44 0.3826088
6 1 45 0.3826088
6 1 46 0.3826088
6 1 47 0.3826088
6 1 48 0.3826088
6 1 49 0.3826088
6 1 50 0.3826088
Y Coordinate Train Table Long Format
Class Time Series Time Index Y
6 1 1 -2.119396
6 1 2 -2.119396
6 1 3 -2.119396
6 1 4 -2.119396
6 1 5 -2.119396
6 1 6 -2.119396
6 1 7 -2.119396
6 1 8 -2.119396
6 1 9 -2.119396
6 1 10 -2.119396
6 1 11 -2.119396
6 1 12 -2.119396
6 1 13 -2.119396
6 1 14 -2.119396
6 1 15 -2.119396
6 1 16 -2.119396
6 1 17 -2.119396
6 1 18 -2.119396
6 1 19 -2.119396
6 1 20 -2.051559
6 1 21 -1.983723
6 1 22 -1.866763
6 1 23 -1.749803
6 1 24 -1.632844
6 1 25 -1.515884
6 1 26 -1.450387
6 1 27 -1.384889
6 1 28 -1.384889
6 1 29 -1.384889
6 1 30 -1.384889
6 1 31 -1.384889
6 1 32 -1.384889
6 1 33 -1.384889
6 1 34 -1.384889
6 1 35 -1.384889
6 1 36 -1.384889
6 1 37 -1.384889
6 1 38 -1.384889
6 1 39 -1.384889
6 1 40 -1.384889
6 1 41 -1.384889
6 1 42 -1.384889
6 1 43 -1.384889
6 1 44 -1.384889
6 1 45 -1.384889
6 1 46 -1.384889
6 1 47 -1.384889
6 1 48 -1.384889
6 1 49 -1.384889
6 1 50 -1.384889
Z Coordinate Train Table Long Format
Class Time Series Time Index Z
6 1 1 -1.528965
6 1 2 -1.528965
6 1 3 -1.528965
6 1 4 -1.528965
6 1 5 -1.528965
6 1 6 -1.528965
6 1 7 -1.528965
6 1 8 -1.528965
6 1 9 -1.528965
6 1 10 -1.528965
6 1 11 -1.528965
6 1 12 -1.528965
6 1 13 -1.528965
6 1 14 -1.528965
6 1 15 -1.528965
6 1 16 -1.528965
6 1 17 -1.528965
6 1 18 -1.528965
6 1 19 -1.528965
6 1 20 -1.518267
6 1 21 -1.507569
6 1 22 -1.489124
6 1 23 -1.470679
6 1 24 -1.452234
6 1 25 -1.433789
6 1 26 -1.423460
6 1 27 -1.413131
6 1 28 -1.413131
6 1 29 -1.413131
6 1 30 -1.413131
6 1 31 -1.413131
6 1 32 -1.413131
6 1 33 -1.413131
6 1 34 -1.413131
6 1 35 -1.413131
6 1 36 -1.413131
6 1 37 -1.413131
6 1 38 -1.413131
6 1 39 -1.413131
6 1 40 -1.413131
6 1 41 -1.413131
6 1 42 -1.413131
6 1 43 -1.413131
6 1 44 -1.413131
6 1 45 -1.413131
6 1 46 -1.413131
6 1 47 -1.413131
6 1 48 -1.413131
6 1 49 -1.413131
6 1 50 -1.413131
Long Data Table with X, Y, and Z Coordinates
Time Series Time Index X Y Z Class
1 1 -0.3042432 -2.119396 -1.528965 6
1 2 -0.3042432 -2.119396 -1.528965 6
1 3 -0.3042432 -2.119396 -1.528965 6
1 4 -0.3042432 -2.119396 -1.528965 6
1 5 -0.3042432 -2.119396 -1.528965 6
1 6 -0.3042432 -2.119396 -1.528965 6
1 7 -0.3042432 -2.119396 -1.528965 6
1 8 -0.3042432 -2.119396 -1.528965 6
1 9 -0.3042432 -2.119396 -1.528965 6
1 10 -0.3042432 -2.119396 -1.528965 6
1 11 -0.3042432 -2.119396 -1.528965 6
1 12 -0.3042432 -2.119396 -1.528965 6
1 13 -0.3042432 -2.119396 -1.528965 6
1 14 -0.3042432 -2.119396 -1.528965 6
1 15 -0.3042432 -2.119396 -1.528965 6
1 16 -0.3042432 -2.119396 -1.528965 6
1 17 -0.3042432 -2.119396 -1.528965 6
1 18 -0.3042432 -2.119396 -1.528965 6
1 19 -0.3042432 -2.119396 -1.528965 6
1 20 -0.2408078 -2.051559 -1.518267 6
1 21 -0.1773724 -1.983723 -1.507569 6
1 22 -0.0680011 -1.866763 -1.489124 6
1 23 0.0413702 -1.749803 -1.470679 6
1 24 0.1507415 -1.632844 -1.452234 6
1 25 0.2601129 -1.515884 -1.433789 6
1 26 0.3213608 -1.450387 -1.423460 6
1 27 0.3826088 -1.384889 -1.413131 6
1 28 0.3826088 -1.384889 -1.413131 6
1 29 0.3826088 -1.384889 -1.413131 6
1 30 0.3826088 -1.384889 -1.413131 6
1 31 0.3826088 -1.384889 -1.413131 6
1 32 0.3826088 -1.384889 -1.413131 6
1 33 0.3826088 -1.384889 -1.413131 6
1 34 0.3826088 -1.384889 -1.413131 6
1 35 0.3826088 -1.384889 -1.413131 6
1 36 0.3826088 -1.384889 -1.413131 6
1 37 0.3826088 -1.384889 -1.413131 6
1 38 0.3826088 -1.384889 -1.413131 6
1 39 0.3826088 -1.384889 -1.413131 6
1 40 0.3826088 -1.384889 -1.413131 6
1 41 0.3826088 -1.384889 -1.413131 6
1 42 0.3826088 -1.384889 -1.413131 6
1 43 0.3826088 -1.384889 -1.413131 6
1 44 0.3826088 -1.384889 -1.413131 6
1 45 0.3826088 -1.384889 -1.413131 6
1 46 0.3826088 -1.384889 -1.413131 6
1 47 0.3826088 -1.384889 -1.413131 6
1 48 0.3826088 -1.384889 -1.413131 6
1 49 0.3826088 -1.384889 -1.413131 6
1 50 0.3826088 -1.384889 -1.413131 6

3. Tasks

3.1. Task A

3D scatter plot as data visualizations for one instance from each class by using plotly package are shown below. The 3D plots somehow fit to the gesture vocabulary, however they are not perfect.

x_coord <- position(x_train, 'X')
y_coord <- position(y_train, 'Y')
z_coord <- position(z_train, 'Z')


a <-plot_ly(x = x_coord[,"position_1"], y = y_coord[,"position_1"], z = z_coord[,"position_1"], type="scatter3d", mode="markers",  scene='scene1') %>%
  layout(title = "Class 1")
b <-plot_ly(x = x_coord[,"position_2"], y = y_coord[,"position_2"], z = z_coord[,"position_2"], type="scatter3d", mode="markers",  scene='scene2') %>%
  layout(title = "Class 2")
c <-plot_ly(x = x_coord[,"position_3"], y = y_coord[,"position_3"], z = z_coord[,"position_3"], type="scatter3d", mode="markers",  scene='scene3') %>%
  layout(title = "Class 3")
d <-plot_ly(x = x_coord[,"position_4"], y = y_coord[,"position_4"], z = z_coord[,"position_4"], type="scatter3d", mode="markers",  scene='scene4') %>%
  layout(title = "Class 4")
e <-plot_ly(x = x_coord[,"position_5"], y = y_coord[,"position_5"], z = z_coord[,"position_5"], type="scatter3d", mode="markers",  scene='scene5') %>%
  layout(title = "Class 5")
f <-plot_ly(x = x_coord[,"position_6"], y = y_coord[,"position_6"], z = z_coord[,"position_6"], type="scatter3d", mode="markers",  scene='scene6') %>%
  layout(title = "Class 6")
g <-plot_ly(x = x_coord[,"position_7"], y = y_coord[,"position_7"], z = z_coord[,"position_7"], type="scatter3d", mode="markers",  scene='scene7') %>%
  layout(title = "Class 7")
h <-plot_ly(x = x_coord[,"position_8"], y = y_coord[,"position_8"], z = z_coord[,"position_8"], type="scatter3d", mode="markers",  scene='scene8') %>%
  layout(title = "Class 8")


fig <- subplot(a, b,c,d,e,f,g,h, nrows=8) 
fig
  • For Class 1: 90 degree turn is obtained, so this instance fits with Gesture 1.
  • For Class 2: 3 sharp 90 degree turns is obtained, so this instance fits with Gesture 2.
  • For Class 3: by changing the viewing angle, a similar shape to Gesture 3 is obtained.
  • For Class 4: by changing the viewing angle, a similar shape to Gesture 4 is obtained.
  • For Class 5: by changing the viewing angle, a similar shape to Gesture 5 is obtained.
  • For Class 6: by changing the viewing angle, a similar shape to Gesture 6 is obtained.
  • For Class 7: 360 degree change is obtained, so this instance fits with Gesture 7.
  • For Class 8: 360 degree change is obtained, so this instance fits with Gesture 8.

3.2. Task B

The data is provided as a regular data matrix (i.e. each row represents an instance and columns represent the time index of the observations). On the other hand, this is an example of multivariate time series where we have X, Y and Z variables. Our aim is to reduce this multivariate time series to a univariate one with a dimensionality reduction approach. One way to achieve this task is to transform the data into the following format.

Data has been already transformed into long format in the data preprocess part. In order to get 1D information from 3D, we should apply Principal component Analysis. However, to do so, we should check the scale of the data. If the variables are not in the same scale, standardization process is needed in order to get variables in the same scale. X, Y, and Z data all have 0 mean and 1 standard deviation, which means we can continue with Principal Component Analysis.

## Importance of components:
##                          Comp.1    Comp.2    Comp.3
## Standard deviation     1.213171 1.0198583 0.6986445
## Proportion of Variance 0.490595 0.3467037 0.1627014
## Cumulative Proportion  0.490595 0.8372986 1.0000000
## 
## Loadings:
##   Comp.1 Comp.2 Comp.3
## X  0.427  0.776  0.464
## Y  0.721        -0.692
## Z  0.546 -0.630  0.553

The summary output shows that with one principal component, 49% of the data can be explained.

PC1 = c(x=0.427, y=0.721, z=0.546)

Therefore, first principal component can be used in order to represent the 3D coordinate data as 1D. Plots belong to random two intances of each classes can be seen below. The time series are similar to each other, which means PCA may be useful to reduce the dimensionality of the data.

It can be concluded that samples from same classes generally resemble each other. However it may not be convenient to differentiate classes by investigating only the first principal component. For example, differentiating class 7 and class 8 is not easy since the shape of the graphs resemble each other.It should be noted that, as in the summary of the PCA, one component can only explain almost the half of the data which means, we lose some information by reducing dimensionality.

3.3. Task C

Now, the data will be filtered for each class and Principal Component Analysis will be applied eight times. We may expect to get better results with this approach, because we reduce the variance among the classes.

For Class 1
## Importance of components:
##                           Comp.1    Comp.2    Comp.3
## Standard deviation     1.1779640 0.9845807 0.8018738
## Proportion of Variance 0.4625331 0.3231331 0.2143339
## Cumulative Proportion  0.4625331 0.7856661 1.0000000
## 
## Loadings:
##   Comp.1 Comp.2 Comp.3
## X  0.357  0.896  0.263
## Y  0.691        -0.720
## Z  0.629 -0.439  0.642
For Class 2
## Importance of components:
##                           Comp.1    Comp.2    Comp.3
## Standard deviation     1.2400176 0.9682706 0.7244366
## Proportion of Variance 0.5125479 0.3125160 0.1749361
## Cumulative Proportion  0.5125479 0.8250639 1.0000000
## 
## Loadings:
##   Comp.1 Comp.2 Comp.3
## X  0.455  0.801  0.388
## Y  0.685        -0.728
## Z  0.569 -0.597  0.565
For Class 3
## Importance of components:
##                          Comp.1    Comp.2    Comp.3
## Standard deviation     1.273669 0.9475424 0.6927707
## Proportion of Variance 0.540744 0.2992789 0.1599771
## Cumulative Proportion  0.540744 0.8400229 1.0000000
## 
## Loadings:
##   Comp.1 Comp.2 Comp.3
## X  0.675         0.738
## Y  0.531  0.689 -0.494
## Z -0.513  0.725  0.460
For Class 4
## Importance of components:
##                           Comp.1    Comp.2    Comp.3
## Standard deviation     1.2846735 0.9605566 0.6534102
## Proportion of Variance 0.5501287 0.3075563 0.1423150
## Cumulative Proportion  0.5501287 0.8576850 1.0000000
## 
## Loadings:
##   Comp.1 Comp.2 Comp.3
## X  0.681  0.113  0.724
## Y  0.634  0.404 -0.659
## Z -0.367  0.908  0.204
For Class 5
## Importance of components:
##                           Comp.1    Comp.2     Comp.3
## Standard deviation     1.3934383 0.9076507 0.48425204
## Proportion of Variance 0.6472234 0.2746099 0.07816668
## Cumulative Proportion  0.6472234 0.9218333 1.00000000
## 
## Loadings:
##   Comp.1 Comp.2 Comp.3
## X  0.399  0.915       
## Y  0.643 -0.321  0.696
## Z  0.654 -0.243 -0.716
For Class 6
## Importance of components:
##                           Comp.1    Comp.2     Comp.3
## Standard deviation     1.3097601 0.9941695 0.54420161
## Proportion of Variance 0.5718239 0.3294577 0.09871846
## Cumulative Proportion  0.5718239 0.9012815 1.00000000
## 
## Loadings:
##   Comp.1 Comp.2 Comp.3
## X  0.206  0.964  0.167
## Y -0.680  0.264 -0.684
## Z -0.704         0.710
For Class 7
## Importance of components:
##                           Comp.1    Comp.2    Comp.3
## Standard deviation     1.2480424 1.0144419 0.6428823
## Proportion of Variance 0.5192033 0.3430308 0.1377659
## Cumulative Proportion  0.5192033 0.8622341 1.0000000
## 
## Loadings:
##   Comp.1 Comp.2 Comp.3
## X  0.229  0.925  0.304
## Y  0.715        -0.697
## Z  0.661 -0.377  0.649
For Class 8
## Importance of components:
##                           Comp.1    Comp.2     Comp.3
## Standard deviation     1.3565694 0.9675745 0.47277805
## Proportion of Variance 0.6134269 0.3120668 0.07450636
## Cumulative Proportion  0.6134269 0.9254936 1.00000000
## 
## Loadings:
##   Comp.1 Comp.2 Comp.3
## X  0.574  0.584  0.574
## Y  0.693        -0.721
## Z  0.436 -0.811  0.389

When we look at the summaries of above R codes,

  • For class 1: 46% of the data can be explained with one component for class 1 whereas it was 49% for the general PCA. Therefore, seperating classes reduce the explainability of one dimension.
  • For class 2: 51% of the data can be explained with one component for class 1 whereas it was 49% for the general PCA. Therefore, seperating classes increse the explainability of one dimension.
  • For class 3: 54% of the data can be explained with one component for class 1 whereas it was 49% for the general PCA. Therefore, seperating classes increse the explainability of one dimension.
  • For class 4: 55% of the data can be explained with one component for class 1 whereas it was 49% for the general PCA. Therefore, seperating classes increse the explainability of one dimension.
  • For class 5: 64% of the data can be explained with one component for class 1 whereas it was 49% for the general PCA. Therefore, seperating classes increse the explainability of one dimension.
  • For class 6: 57% of the data can be explained with one component for class 1 whereas it was 49% for the general PCA. Therefore, seperating classes increse the explainability of one dimension.
  • For class 7: 51% of the data can be explained with one component for class 1 whereas it was 49% for the general PCA. Therefore, seperating classes increse the explainability of one dimension.
  • For class 8: 61% of the data can be explained with one component for class 1 whereas it was 49% for the general PCA. Therefore, seperating classes increse the explainability of one dimension.

In general, we can say that applying PCA for almost every class gives better results than applying to all class.

3.4. Task D

Our aim now is to visualize the time series in reduced dimensions for classification purposes. We compute the distance between the time series for each axis using the original representation (i.e. a row represents individual time series, column is the time index and entries are the observations) over each axis and sum them up to obtain a final distance measure. Then, multidimensional scaling is applied to this distance matrix to represent each time series on a 2-dimensional feature space.

The purpose of this approach is that there are 315 time ordered information in this dataset. This is a great number in order to consider as feature number in a model therefore, reducing the number of features may be a good approach. To do so, we use multi dimensional scaling (MDS) approach. Firstly, we need to create the distance matrix. We can get distance matrix by using dist function, and manhattan method, since we need to sum all distances of axes and this summation will be in a way like manhattan.

After constructing the distance matrix, multidimensional scaling meyhod can be used. Visualization of the observations using the reduced features and color-code the points is presented below.

Following conclusions can be obtained from the above plot:

  • Observations from the same classes are tend to cluster mostly.
  • Some classes are very close to each other such as class 2 & class 7, class 1 & class 6, class 4 & class 8.
  • Class 3 is very widespread.
  • Some classes are distinguishable but not all of them. For example, class 5 & class 2 are distinguishable whereas class 1 & class 6 are almost indistinguishable.
  • The gestures with the opposite moves can be seen distinctly in the classification plot.
  • Multidimensional Scaling method is an effective way to distinguish some classes from other but not for all the classes.
  • The variance is very large for some classes therefore some classes overlap.